// 设置部分
const zwglTaskConfig = (request) => {
	return {
        view_zwglTaskConfig_add(query = {}) {
            return request(`/bussiness/zwglTaskConfig/add`, {
                method: 'post',
                data: query,
            })
        },
        view_zwglTaskConfig_edit(query = {}) {
            return request(`/bussiness/zwglTaskConfig/edit`, {
                method: 'post',
                data: query,
            })
        },
        // 列表
        view_zwglTaskConfig_page(query = {}) {
            return request(`/bussiness/zwglTaskConfig/page`, {
                method: 'post',
                data: query,
            })
        },
        // 导出
        view_zwglTaskInfo_export(query = {}) {
            return request(`/bussiness/zwglTaskInfo/export`, {
                method: 'post',
                data: query,
            })
        },
        // 修改
        view_zwglTaskInfo_edit(query = {}) {
            return request(`/bussiness/zwglTaskInfo/edit`, {
                method: 'post',
                data: query,
            })
        },
          // 添加
        view_zwglTaskInfo_add(query = {}) {
            return request(`/bussiness/zwglTaskInfo/add`, {
                method: 'post',
                data: query,
            })
        },
        // 结束任务
        view_zwglMainTaskInfo_finish(query = {}) {
            return request(`/bussiness/zwglTaskInfo/finish`, {
                method: 'post',
                data: query,
            })
        },
        // 删除
        view_zwglMainTaskInfo_del(ids) {
            return request(`/bussiness/zwglTaskInfo/mainDel`, {
                method: 'post',
                data: {
                    batchesDel:ids
                },
            })
        },
	}
}

// 总任务
const zwglTaskInfo = (request) => {
	return {
        // 总任务列表（view_zwglSubTaskInfo_list）
        view_zwglMainTaskInfo_mainPage(query = {}) {
            return request(`/bussiness/zwglTaskInfo/mainPage`, {
                method: 'post',
                data: query,
            })
        },
        // 总任务添加
        view_zwglMainTaskInfo_add(query = {}) {
            return request(`/bussiness/zwglTaskInfo/add`, {
                method: 'post',
                data: query,
            })
        },
        // 总任务编辑
        view_zwglMainTaskInfo_edit(query = {}) {
            return request(`/bussiness/zwglTaskInfo/edit`, {
                method: 'post',
                data: query,
            })
        },
        // 子任务列表
        view_zwglSubTaskInfo_subPage(query = {}) {
            return request(`/bussiness/zwglTaskInfo/subPage`, {
                method: 'post',
                data: query,
            })
        },
        // 树形子任务
        view_zwglTaskInfo_tree(query = {}){
            return request(`/bussiness/zwglTaskInfo/taskInfoTree`, {
                method: 'post',
                data: query,
            })
        },
        // 通过id获取表格
        view_zwglTaskInfo_view(id){
            return request(`/bussiness/zwglTaskInfo/${id}`, {
                method: 'get',
            })
        },
        // 下级向上级提交
        view_zwglTaskInfo_submit(query = {}){
            return request(`/bussiness/zwglTaskInfo/submit`, {
                method: 'post',
                data: query,
            })
        },
        // 审批
        view_zwglTaskInfo_approval(query = {}){
            return request(`/bussiness/zwglTaskInfo/approval`, {
                method: 'post',
                data: query,
            })
        },
        // 批量审批
        view_zwglTaskInfo_batchApproval(query = {}){
            return request(`/bussiness/zwglTaskInfo/batchApproval`, {
                method: 'post',
                data: query,
            })
        },
        //zwglTaskInfo/subDel
        view_zwglSubTaskInfo_del(query = {}){
            return request(`/bussiness/zwglTaskInfo/subDel`, {
                method: 'post',
                data: query,
            })
        },
	}
}
// 评价列表
const zwglTaskRemark = (request) => {
	return {
         // 评价列表
         view_zwglTaskRemark_list(query = {}){
            return request(`/bussiness/zwglTaskRemark/list`, {
                method: 'post',
                data: query,
            })
        },
        // 提交
        view_zwglTaskRemark_add(query = {}){
            return request(`/bussiness/zwglTaskRemark/add`, {
                method: 'post',
                data: query,
            })
        },
    }
}
// 归档
const zwglTaskDataFiling = (request) => {
	return {
         // 归档列表
         view_zwglTaskDataFiling_page(query = {}){
            return request(`/bussiness/zwglTaskDataFiling/page`, {
                method: 'post',
                data: query,
            })
        }
    }
}

export default ({ request }: any) => ({
	...zwglTaskConfig(request),
    ...zwglTaskInfo(request),
    ...zwglTaskRemark(request),
    ...zwglTaskDataFiling(request)
})